<#include "/include/publish/macros.ftl">
<#setting number_format="#">
<@simpleheader>

</@simpleheader>
<form id="publishForm" style="height:100%">
                    <div class="item" style="height:100%">
                            <input type="hidden" name="isMarkdown" value="0">
                            <input type="hidden" name="id">
                            <div class="col-md-8 col-sm-8 col-xs-12">
                                <input type="text" class="form-control col-md-7 col-xs-12" name="title" id="title" required="required" placeholder="请输入标题"/>
                            </div>
                        <label class="control-label col-md-1 col-sm-1 col-xs-12" for="password">内容 <span class="required">*</span></label>
                        <div class="col-md-11 col-sm-11 col-xs-12" style="height:80%">
                            <div id="editor" style="height:90%"></div>
                        </div>
                        <div class="navbar-fixed-bottom" style="height:8%">
                        <label class="control-label col-md-1 col-sm-1 col-xs-12"></label>
                        <div class="col-md-10 col-sm-10 col-xs-12">
                            <button type="button" class="btn btn-success to-choose-info"><i class="fa fa-pencil"> 发布文章</i></button>
                        </div>
                    </div>
   <@userpublishmodal></@userpublishmodal>
</form>
<@chooseImgModal></@chooseImgModal>
<@userfooter>
    <script>
        articleId = '${id}';
        $(function () {
            zhyd.wangEditor.init({
                container: "#editor",
                textareaName: "content",
                uploadUrl: "/api/uploadFile",
                uploadFileName: "file",
                uploadType: "article",
                // customCss: {
                //     "height": "100%",
                //     "max-height": "115px"
                // }
            })
        });
    </script>
    <script src="${config.staticWebSite}/assets/js/zhyd.user.publish-article.js"></script>
</@userfooter>
